package com.sky.mapper;

import com.github.pagehelper.Page;
import com.sky.dto.OrdersPageQueryDTO;
import com.sky.entity.Orders;
import org.apache.ibatis.annotations.Mapper;

import java.util.Map;

/**
 * @version 1.0.0
 * @program:sky-take-out
 * @author: CaoYuWei
 * @create:2023-02-11 14:47:57
 **/
@Mapper
public interface OrderMapper {



    void insert(Orders orders);

    /**
     * 分页查询
     * @param ordersPageQueryDTO
     * @return
     */
    Page<Orders> selectHistoryOrders(OrdersPageQueryDTO ordersPageQueryDTO);


    /**
     * 查询id
     * @param id
     * @return
     */
    Orders getById(Long id);

    /**
     * 取消订单
     * @param orders
     */
    void update(Orders orders);

    /**
     * 订单查询
     * @param ordersPageQueryDTO
     * @return
     */
    Page<Orders> orderSelect(OrdersPageQueryDTO ordersPageQueryDTO);
}